<!-- saved from url=(0014)about:internet -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>PropertyInfoObj.as</title>
<link rel="stylesheet" type="text/css" href="../../../SourceStyles.css"/>
</head>

<body><pre><span class="ActionScriptpackage">package</span> <span class="ActionScriptDefault_Text">caurina</span>.<span class="ActionScriptDefault_Text">transitions</span> <span class="ActionScriptBracket/Brace">{</span>

    <span class="ActionScriptASDoc">/**
     * PropertyInfoObj
     * An object containing the updating info for a given property (its starting value, and its final value)
     *
     * @author        Zeh Fernando
     * @version        1.0.0
     * @private
     */</span>

    <span class="ActionScriptReserved">public</span> <span class="ActionScriptclass">class</span> <span class="ActionScriptDefault_Text">PropertyInfoObj</span> <span class="ActionScriptBracket/Brace">{</span>
        
        <span class="ActionScriptReserved">public</span> <span class="ActionScriptvar">var</span> <span class="ActionScriptDefault_Text">valueStart</span>                <span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Number</span>;    <span class="ActionScriptComment">// Starting value of the tweening (null if not started yet)
</span>        <span class="ActionScriptReserved">public</span> <span class="ActionScriptvar">var</span> <span class="ActionScriptDefault_Text">valueComplete</span>            <span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Number</span>;    <span class="ActionScriptComment">// Final desired value
</span>        <span class="ActionScriptReserved">public</span> <span class="ActionScriptvar">var</span> <span class="ActionScriptDefault_Text">hasModifier</span>                <span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Boolean</span>;    <span class="ActionScriptComment">// Whether or not it has a modifier function
</span>        <span class="ActionScriptReserved">public</span> <span class="ActionScriptvar">var</span> <span class="ActionScriptDefault_Text">modifierFunction</span>        <span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Function</span>;    <span class="ActionScriptComment">// Modifier function, if any
</span>        <span class="ActionScriptReserved">public</span> <span class="ActionScriptvar">var</span> <span class="ActionScriptDefault_Text">modifierParameters</span>        <span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Array</span>;        <span class="ActionScriptComment">// Additional array of modifier parameters
</span>
        <span class="ActionScriptComment">// ==================================================================================================================================
</span>        <span class="ActionScriptComment">// CONSTRUCTOR function -------------------------------------------------------------------------------------------------------------
</span>
        <span class="ActionScriptASDoc">/**
         * Initializes the basic PropertyInfoObj.
         * 
         * @param    p_valueStart        Number        Starting value of the tweening (null if not started yet)
         * @param    p_valueComplete        Number        Final (desired) property value
         */</span>
        <span class="ActionScriptfunction">function</span> <span class="ActionScriptDefault_Text">PropertyInfoObj</span><span class="ActionScriptBracket/Brace">(</span><span class="ActionScriptDefault_Text">p_valueStart</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Number</span>, <span class="ActionScriptDefault_Text">p_valueComplete</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Number</span>, <span class="ActionScriptDefault_Text">p_modifierFunction</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Function</span>, <span class="ActionScriptDefault_Text">p_modifierParameters</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">Array</span><span class="ActionScriptBracket/Brace">)</span> <span class="ActionScriptBracket/Brace">{</span>
            <span class="ActionScriptDefault_Text">valueStart</span>            <span class="ActionScriptOperator">=</span>    <span class="ActionScriptDefault_Text">p_valueStart</span>;
            <span class="ActionScriptDefault_Text">valueComplete</span>        <span class="ActionScriptOperator">=</span>    <span class="ActionScriptDefault_Text">p_valueComplete</span>;
            <span class="ActionScriptDefault_Text">hasModifier</span>            <span class="ActionScriptOperator">=</span>    <span class="ActionScriptDefault_Text">Boolean</span><span class="ActionScriptBracket/Brace">(</span><span class="ActionScriptDefault_Text">p_modifierFunction</span><span class="ActionScriptBracket/Brace">)</span>;
            <span class="ActionScriptDefault_Text">modifierFunction</span>     <span class="ActionScriptOperator">=</span>    <span class="ActionScriptDefault_Text">p_modifierFunction</span>;
            <span class="ActionScriptDefault_Text">modifierParameters</span>    <span class="ActionScriptOperator">=</span>    <span class="ActionScriptDefault_Text">p_modifierParameters</span>;
        <span class="ActionScriptBracket/Brace">}</span>


        <span class="ActionScriptComment">// ==================================================================================================================================
</span>        <span class="ActionScriptComment">// OTHER functions ------------------------------------------------------------------------------------------------------------------
</span>
        <span class="ActionScriptASDoc">/**
         * Clones this property info and returns the new PropertyInfoObj
         *
         * @param    omitEvents        Boolean            Whether or not events such as onStart (and its parameters) should be omitted
         * @return                     TweenListObj    A copy of this object
         */</span>
        <span class="ActionScriptReserved">public</span> <span class="ActionScriptfunction">function</span> <span class="ActionScriptDefault_Text">clone</span><span class="ActionScriptBracket/Brace">()</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">PropertyInfoObj</span> <span class="ActionScriptBracket/Brace">{</span>
            <span class="ActionScriptvar">var</span> <span class="ActionScriptDefault_Text">nProperty</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">PropertyInfoObj</span> <span class="ActionScriptOperator">=</span> <span class="ActionScriptReserved">new</span> <span class="ActionScriptDefault_Text">PropertyInfoObj</span><span class="ActionScriptBracket/Brace">(</span><span class="ActionScriptDefault_Text">valueStart</span>, <span class="ActionScriptDefault_Text">valueComplete</span>, <span class="ActionScriptDefault_Text">modifierFunction</span>, <span class="ActionScriptDefault_Text">modifierParameters</span><span class="ActionScriptBracket/Brace">)</span>;
            <span class="ActionScriptReserved">return</span> <span class="ActionScriptDefault_Text">nProperty</span>;
        <span class="ActionScriptBracket/Brace">}</span>

        <span class="ActionScriptASDoc">/**
         * Returns this object described as a String.
         *
         * @return                     String        The description of this object.
         */</span>
        <span class="ActionScriptReserved">public</span> <span class="ActionScriptfunction">function</span> <span class="ActionScriptDefault_Text">toString</span><span class="ActionScriptBracket/Brace">()</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">String</span> <span class="ActionScriptBracket/Brace">{</span>
            <span class="ActionScriptvar">var</span> <span class="ActionScriptDefault_Text">returnStr</span><span class="ActionScriptOperator">:</span><span class="ActionScriptDefault_Text">String</span> <span class="ActionScriptOperator">=</span> <span class="ActionScriptString">&quot;\n[PropertyInfoObj &quot;</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;valueStart:&quot;</span> <span class="ActionScriptOperator">+</span> <span class="ActionScriptDefault_Text">String</span><span class="ActionScriptBracket/Brace">(</span><span class="ActionScriptDefault_Text">valueStart</span><span class="ActionScriptBracket/Brace">)</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;, &quot;</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;valueComplete:&quot;</span> <span class="ActionScriptOperator">+</span> <span class="ActionScriptDefault_Text">String</span><span class="ActionScriptBracket/Brace">(</span><span class="ActionScriptDefault_Text">valueComplete</span><span class="ActionScriptBracket/Brace">)</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;, &quot;</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;modifierFunction:&quot;</span> <span class="ActionScriptOperator">+</span> <span class="ActionScriptDefault_Text">String</span><span class="ActionScriptBracket/Brace">(</span><span class="ActionScriptDefault_Text">modifierFunction</span><span class="ActionScriptBracket/Brace">)</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;, &quot;</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;modifierParameters:&quot;</span> <span class="ActionScriptOperator">+</span> <span class="ActionScriptDefault_Text">String</span><span class="ActionScriptBracket/Brace">(</span><span class="ActionScriptDefault_Text">modifierParameters</span><span class="ActionScriptBracket/Brace">)</span>;
            <span class="ActionScriptDefault_Text">returnStr</span> <span class="ActionScriptOperator">+=</span> <span class="ActionScriptString">&quot;]\n&quot;</span>;
            <span class="ActionScriptReserved">return</span> <span class="ActionScriptDefault_Text">returnStr</span>;
        <span class="ActionScriptBracket/Brace">}</span>
        
    <span class="ActionScriptBracket/Brace">}</span>

<span class="ActionScriptBracket/Brace">}</span></pre></body>
</html>
